package com.heima.service.Impl;

import com.heima.dao.AccountDao;
import com.heima.pojo.Account;
import com.heima.service.AccountService;

import java.util.List;

public class AccountServiceImpl implements AccountService {
    AccountDao accountDao;
    public void setAccountDao(AccountDao accountDao) {
        this.accountDao = accountDao;
    }
    @Override
    public int add(Account account) {
        return accountDao.add(account);
    }
    @Override
    public int update(Account account) {
        return accountDao.update(account);
    }
    @Override
    public int delete(Integer id) {
        return accountDao.delete(id);
    }
    @Override
    public List<Account> findAll() {
        return accountDao.findAll();
    }
    @Override
    public Account findById(Integer id) {
        return accountDao.findById(id);
    }
}